From: Colin Walters Date: Sun, 24 Jul 2016 19:40:22 +0000 (-0400) Subject: sysroot: Fix a leak in deployment dirpath API X-Git-Tag: archive/raspbian/2022.1-3+rpi1~1^2~4^2~49^2~55 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=707ef9309747dc8a429c42443d8c2c1adade18ed;p=ostree.git sysroot: Fix a leak in deployment dirpath API This one is pretty obvious in retrospect. Closes: #410 Approved by: giuseppe --- diff --git a/src/libostree/ostree-sysroot.c b/src/libostree/ostree-sysroot.c index 7cc4c9f5..2a55c6b1 100644 --- a/src/libostree/ostree-sysroot.c +++ b/src/libostree/ostree-sysroot.c @@ -1003,7 +1003,8 @@ GFile * ostree_sysroot_get_deployment_directory (OstreeSysroot *self, OstreeDeployment *deployment) { - return g_file_resolve_relative_path (self->path, ostree_sysroot_get_deployment_dirpath (self, deployment)); + g_autofree char *dirpath = ostree_sysroot_get_deployment_dirpath (self, deployment); + return g_file_resolve_relative_path (self->path, dirpath); } /**